3.1907 \(\int (1+\frac{1}{x}+x) \, dx\)

Optimal. Leaf size=11 \[ \frac{x^2}{2}+x+\log (x) \]

[Out]

x + x^2/2 + Log[x]

________________________________________________________________________________________

Rubi [A]  time = 0.0013859, antiderivative size = 11, normalized size of antiderivative = 1., number of steps used = 1, number of rules used = 0, integrand size = 6, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0., Rules used = {} \[ \frac{x^2}{2}+x+\log (x) \]

Antiderivative was successfully verified.

[In]

Int[1 + x^(-1) + x,x]

[Out]

x + x^2/2 + Log[x]

Rubi steps

\begin{align*} \int \left (1+\frac{1}{x}+x\right ) \, dx &=x+\frac{x^2}{2}+\log (x)\\ \end{align*}

Mathematica [A]  time = 0.0005127, size = 11, normalized size = 1. \[ \frac{x^2}{2}+x+\log (x) \]

Antiderivative was successfully verified.

[In]

Integrate[1 + x^(-1) + x,x]

[Out]

x + x^2/2 + Log[x]

________________________________________________________________________________________

Maple [A]  time = 0., size = 10, normalized size = 0.9 \begin{align*} x+{\frac{{x}^{2}}{2}}+\ln \left ( x \right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1+1/x+x,x)

[Out]

x+1/2*x^2+ln(x)

________________________________________________________________________________________

Maxima [A]  time = 0.952602, size = 12, normalized size = 1.09 \begin{align*} \frac{1}{2} \, x^{2} + x + \log \left (x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1+1/x+x,x, algorithm="maxima")

[Out]

1/2*x^2 + x + log(x)

________________________________________________________________________________________

Fricas [A]  time = 1.95136, size = 30, normalized size = 2.73 \begin{align*} \frac{1}{2} \, x^{2} + x + \log \left (x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1+1/x+x,x, algorithm="fricas")

[Out]

1/2*x^2 + x + log(x)

________________________________________________________________________________________

Sympy [A]  time = 0.070122, size = 8, normalized size = 0.73 \begin{align*} \frac{x^{2}}{2} + x + \log{\left (x \right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1+1/x+x,x)

[Out]

x**2/2 + x + log(x)

________________________________________________________________________________________

Giac [A]  time = 1.04252, size = 14, normalized size = 1.27 \begin{align*} \frac{1}{2} \, x^{2} + x + \log \left ({\left | x \right |}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1+1/x+x,x, algorithm="giac")

[Out]

1/2*x^2 + x + log(abs(x))